package com.codi.jobservice.job;

import com.codi.base.exception.BaseAppException;
import com.codi.base.spring.SpringContextHolder;
import com.codi.bus.core.service.FundCombinationService;
import org.quartz.DisallowConcurrentExecution;
import org.quartz.JobExecutionContext;
import org.quartz.JobExecutionException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.scheduling.quartz.QuartzJobBean;

/**
 * 刷新基金组合信息
 */
@DisallowConcurrentExecution
public class FundCombinationJob extends QuartzJobBean {
    private static final Logger logger = LoggerFactory.getLogger(QuartzJobBean.class);

    @Override
    protected void executeInternal(JobExecutionContext jobExecutionContext) throws JobExecutionException {
//        logger.info("begin************************");
//        FundCombinationService fundCombinationService = SpringContextHolder.getBean("fundCombinationService");
//        logger.info("{}" + fundCombinationService);
//        try {
//            logger.info("begin doing");
//            fundCombinationService.updateFundCombination();
//            logger.info("end.....");
//        } catch (BaseAppException e) {
//            logger.error(e.getMessage(), e);
//        }
    }
}
